home *** CD-ROM | disk | FTP | other *** search
- *****************************************************************************
- *:
- *: CLIPDOS.LIB, CLIPDOS.OBJ, SAMPLE.PRG - November 1991
- *: Michael Blankenship, Innovative Computer Solutions
- *:
- *: The following program demonstrates some of the functions included in
- *: the CLIPDOS library.
- *:
- *: [The CURDIR() function is part of the Clipper language.]
- *:
- *:
- *: Feel free to use variable names by reference (or macro substitution)
- *: as you normally would with Clipper functions, for example:
- *:
- *: STORE "C:\\DBASE\\DATA" TO NewDir
- *: STORE "C:\\DBASE" TO ThisDir
- *: ChangeDir(ThisDir)
- *: MakeDir(NewDir)
- *:
- *: The following program is the smallest and most simple one that I
- *: could quickly create to show all of the new functions. I realize
- *: that there are many other different (better) ways to display text
- *: and to show off these utilities.
- *:
- *: The following lines will compile and link SAMPLE.PRG into SAMPLE.EXE:
- *:
- *: CLIPPER SAMPLE
- *: TLINK SAMPLE,,,CLIPPER EXTEND CL CLIPDOS
- *:
- *: (See notes in CLIPDOS.DOC on whereabouts of CL.LIB and what to do if
- *: you are using a different linker.)
- *:
- *****************************************************************************
-
- CLEAR
- ? "Current drive: "+GetDrive()+":"
- ? "Current directory: \"+CURDIR()
- ? ""
- ? "Making new directory using MakeDir()..."
- IF MakeDir("hello") = 0
- ? "Successful creation of HELLO subdirectory"
- ELSE
- ? "Unsuccesful creation of new subdirectory"
- ENDIF
- ? ""
- ? "Changing to new directory using ChangeDir()..."
- IF ChangeDir("hello") = 0
- ? "Successful change to HELLO subdirectory"
- ELSE
- ? "Unsuccessful change to new subdirectory"
- ENDIF
- ? ""
- ? "Current drive: "+GetDrive()+":"
- ? "Current directory: \"+CURDIR()
- ? ""
- ? "Changing the current drive with ChangeDrive()..."
- ? "DOS is currently set up for "+LTRIM(STR(ChangeDrv("C")))
- ?? " drives in this system."
- ? ""
- ? "Current drive: "+GetDrive()+":"
- ? "Current directory: \"+CURDIR()
- ? ""
-